<?php

class Bootstrap extends Zend_Application_Bootstrap_Bootstrap
{
	protected function __initSession(){
		Zend_Session::start();
	}
	
	protected function _initAutoload(){
		$options = $this->getOptions();
		
		$moduleLoader = new Zend_Application_Module_Autoloader(array(
					'namespace' => '',
					'basePath' => APPLICATION_PATH));
		
		$auth = Zend_Auth::getInstance();
		
		$frontController = Zend_Controller_Front::getInstance();
		$frontController->registerPlugin(new Application_Plugin_SeguridadAcceso($auth, $options['blackList']));
		
		return $moduleLoader;
	}
	
	
	protected function _initViewHelpers(){
		$this->bootstrap('layout');
		$layout = $this->getResource('layout');
		$view = $layout->getView();
		$view->doctype=('<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">');
//		$view->headMeta()->appendHttpEquiv('Content-Type', 'text/html; charset=iso-8859-1');
		$view->headMeta()->appendHttpEquiv('Content-Type', 'text/html; charset=utf-8');
		
		$view->headTitle()->setSeparator(' - ');
		$view->headTitle('Sigta Plataforma Web');
		Zend_Session::start();
		
	}

}

